package cn.ymkj.service.impl;

import cn.ymkj.pojo.Menu;
import cn.ymkj.service.MenuService;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

@Service
public class MenuServiceImpl implements MenuService {

    @Override
    public List<Menu> findAll() {
        List<Menu> menuList = new ArrayList<>();

        List<Menu> menuList1 = new ArrayList<>();
        menuList1.add(new Menu(2001,"用户管理","/user",1001,null));
        menuList1.add(new Menu(2002,"部门管理","/dept",1001,null));
        menuList.add(new Menu(1001,"基础管理",null,0,menuList1));

        List<Menu> menuList2 = new ArrayList<>();
        menuList2.add(new Menu(2003,"日志管理","/logs",1002,null));
        menuList.add(new Menu(1002,"系统管理","null",0,menuList2));

        return menuList;
    }
}
